Repository navigation
fix: refuse a blank --tool instead of sending without a tool - #80
Merged
Merged
Conversation
`--tool " "` (an empty script variable, say) was accepted, and the prompt went out with no tool and no warning (measured 2026-10-29). MCP pro_consult passes its tools as --tool, so a blank entry there did the same. A tool is opened by its label, so a value of only spaces names none; the send now stops before the browser with "--tool is blank". Verified: tsc, build, npm test (1844 passed, 3 skipped). The new CLI and MCP tests fail without the change. The built CLI refuses `--tool " "` with exit 1 and never takes the browser send lock. Claude-Session: https://claude.ai/code/session_01EMqNwnnhHXznd2P2PDsaDV
What this touches
4 file(s), 30 line(s) changed. Tests changed. This is an automated first pass, not a review. CI is the gate; a person decides. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
# Conflicts: # CHANGELOG.md
youdie006
added a commit
that referenced
this pull request
Oct 30, 2026
A blank --tool (or a blank MCP pro_consult tools entry) was accepted and the prompt went out with no tool. It now stops before the browser with "--tool is blank". The patch from main applied as-is. Verified: tsc, build, npm test. Claude-Session: https://claude.ai/code/session_01EMqNwnnhHXznd2P2PDsaDV
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
--tool " "(a tool name of only spaces, such as an empty script variable) was accepted. The prompt went out with no tool and no warning (measured 2026-10-29). MCPpro_consultpasses itstoolsto the CLI as--tool, so a blank entry there did the same.Change
A blank
--toolvalue now stops the send before the browser: "--tool is blank; name a composer tool (web-search, create-image), or leave the option out." This matches how blank--project/--project-neware already refused. An empty string was already refused as "--tool requires a value".Verification
tsc --noEmit,npm run build,npm test: 1844 passed, 3 skipped.tests/cli-pro-browser-send.test.ts(spaces, tab) andtests/mcp-consult.test.ts(MCPtools: [" "]). All fail without the change: the send was reached.prodex ask --tool " " ...exits 1 with the message, and no browser send lock is taken.